package com.bileetacrm;

import com.bileetacrm.SimpleGestureFilter.SimpleGestureListener;
import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.support.v4.app.Fragment;
import android.util.Log;
import android.view.LayoutInflater;
import android.view.MotionEvent;
import android.view.View;
import android.view.ViewGroup;
import android.view.Window;
import android.view.WindowManager;
import android.widget.Button;
import android.widget.RelativeLayout;
import android.widget.Toast;

public class BileetaSalesInquiryListActivity extends Fragment {
	protected static final String TAG = null;
	private SimpleGestureFilter detector;
	Button addnewleadinfo;
	RelativeLayout viewInquirySummary;
	/*public void viewInquirySummary(View view) {
		Intent myIntent = new Intent(view.getContext(), BileetaSalesInquirySummaryActivity.class);
		startActivityForResult(myIntent, 0);
	}
	*/
	@Override
	public View onCreateView(LayoutInflater inflater, ViewGroup container,
			Bundle savedInstanceState) {
		View view = inflater.inflate(
				R.layout.bileeta_sales_inquiry_list_activity, container, false);

		/*
		 * dbHelper = new MySqlLiteHelper(getActivity()); database =
		 * dbHelper.getWritableDatabase();
		 */
		viewInquirySummary =  (RelativeLayout) view.findViewById(R.id.viewInquirySummary1);
		viewInquirySummary.setOnClickListener(new View.OnClickListener() {
			@Override
			public void onClick(View v) {
				Log.v(TAG, "*****viewInquirySummary*****");
				Intent myIntent = new Intent(v.getContext(),
						BileetaSalesInquirySummaryActivity.class);
				startActivityForResult(myIntent, 0);

			}
		});
		viewInquirySummary =  (RelativeLayout) view.findViewById(R.id.viewInquirySummary2);
		viewInquirySummary.setOnClickListener(new View.OnClickListener() {
			@Override
			public void onClick(View v) {
				Log.v(TAG, "*****viewInquirySummary*****");
				Intent myIntent = new Intent(v.getContext(),
						BileetaSalesInquirySummaryActivity.class);
				startActivityForResult(myIntent, 0);

			}
		});
		viewInquirySummary =  (RelativeLayout) view.findViewById(R.id.viewInquirySummary3);
		viewInquirySummary.setOnClickListener(new View.OnClickListener() {
			@Override
			public void onClick(View v) {
				Log.v(TAG, "*****viewInquirySummary*****");
				Intent myIntent = new Intent(v.getContext(),
						BileetaSalesInquirySummaryActivity.class);
				startActivityForResult(myIntent, 0);

			}
		});
		viewInquirySummary =  (RelativeLayout) view.findViewById(R.id.viewInquirySummary4);
		viewInquirySummary.setOnClickListener(new View.OnClickListener() {
			@Override
			public void onClick(View v) {
				Log.v(TAG, "*****viewInquirySummary*****");
				Intent myIntent = new Intent(v.getContext(),
						BileetaSalesInquirySummaryActivity.class);
				startActivityForResult(myIntent, 0);

			}
		});
		viewInquirySummary =  (RelativeLayout) view.findViewById(R.id.viewInquirySummary5);
		viewInquirySummary.setOnClickListener(new View.OnClickListener() {
			@Override
			public void onClick(View v) {
				Log.v(TAG, "*****viewInquirySummary*****");
				Intent myIntent = new Intent(v.getContext(),
						BileetaSalesInquirySummaryActivity.class);
				startActivityForResult(myIntent, 0);

			}
		});
		viewInquirySummary =  (RelativeLayout) view.findViewById(R.id.viewInquirySummary6);
		viewInquirySummary.setOnClickListener(new View.OnClickListener() {
			@Override
			public void onClick(View v) {
				Log.v(TAG, "*****viewInquirySummary*****");
				Intent myIntent = new Intent(v.getContext(),
						BileetaSalesInquirySummaryActivity.class);
				startActivityForResult(myIntent, 0);

			}
		});
		Button buttonAddInquiry = (Button) view
				.findViewById(R.id.menu_add_inquiry);
		buttonAddInquiry.setOnClickListener(new View.OnClickListener() {
			@Override
			public void onClick(View v) {
				Intent myIntent = new Intent(v.getContext(),
						BileetaAddNewInquery.class);
				startActivityForResult(myIntent, 0);

			}
		});

		Button buttonAddEvent = (Button) view.findViewById(R.id.menu_add_event);
		buttonAddEvent.setOnClickListener(new View.OnClickListener() {
			@Override
			public void onClick(View v) {
				Intent myIntent = new Intent(v.getContext(),
						BileetaAddNewEvent.class);
				startActivityForResult(myIntent, 0);

			}
		});

		Button buttonAddtionalInfo = (Button) view
				.findViewById(R.id.menu_additional_info);
		buttonAddtionalInfo.setOnClickListener(new View.OnClickListener() {
			@Override
			public void onClick(View v) {
				Intent myIntent = new Intent(v.getContext(),
						BileetaAddLeadAdditionalInfo.class);
				startActivityForResult(myIntent, 0);

			}
		});

		Button buttonAddContact = (Button) view
				.findViewById(R.id.menu_add_to_contacts);
		buttonAddContact.setOnClickListener(new View.OnClickListener() {
			@Override
			public void onClick(View v) {
				Intent myIntent = new Intent(v.getContext(),
						BileetaAddContactInformation.class);
				startActivityForResult(myIntent, 0);

			}
		});
		
		
		Button displayDetailsView = (Button) view
				.findViewById(R.id.addnewleadinfo);
		displayDetailsView.setOnClickListener(new View.OnClickListener() {
			@Override
			public void onClick(View v) {
				
				Intent myIntent = new Intent(v.getContext(),
						BileetaFragmentActivity.class);
				myIntent.putExtra("TAGID", "1");
				startActivityForResult(myIntent, 0);
			}
		});
		return view;
	}

}
